home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Loadstar 223
/
223.d81
/
t.tile stylist
< prev
next >
Wrap
Text File
|
2022-08-26
|
5KB
|
188 lines
u
T I L E S T Y L I S T
by Brian Boese
Let me begin with a confession.
I've been using a Macintosh lately.
Yes, I know it's wrong, but life is
not always fair. I have to. It's my
job.
Forgive me for saying this, but
there are a few features of the Mac
that I really like, one of which is
its snazzy window screens with catchy
backgrounds. Why can't the same thing
be done on a C-64, without going into
those strange screen modes that Dave
Johannsen uses in QUADRILATION and
TRIANGULATION?
Well, it CAN be done.
My technique is so simple it's a
wonder that it hasn't been used
before. I mean, it is really obvious,
once you've seen it working before
your eyes.
All I did was make a font and
edited the space character. That's it.
Now, wherever I want the pattern (or
tile) to appear, I put a space. To
tile the entire screen with the
pattern, I set the print colour to
what I want and clear the screen. When
a screen is cleared, it's actually
filled with a bunch of spaces. In
order to get a normal, blank-looking
space on the screen I used a
SHIFT-SPACE.
That's it!
[DAVE'S NOTE:] And I thought Fender
and Jeff stayed up late into the early
morning manipulating screen pixels
with arcane and eldrich spells and
amulets. Silly me!
To show off my artistic talent, I
edited all of the reverse characters
of a font to be decent-looking tile
patterns. The Run It program on the
disk is a simple demo to show you how
attractive these tiles can be when you
put a lot of them together as a
background.
You can use this same technique to
make your window programs look more
professional. Use some of my patterns,
or make some of your own. I recommend
you only use a few in any one program,
as overdoing it can spoil the effect.
(And ruin reader's eye sight. -Ed.) If
you want, you can let the user of your
programs select a pre-made pattern
that you already have set up.
Try it, programmers! It's easy.
BB
[FENDER'S COMMENTS:] Brian is right
about tiling being easy, especially
when you use the SPACE character as
your tile. However, I can imagine that
it might get a little old having to
remember to use a SHIFT-SPACE every
time you wanted a regular space. In
this case, why not define some un-used
character (like the \) as the tile and
then define a string as
Q$="\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
\\\\\\\"
and instead of clearing the screen,
just do something like
PRINT"[CLR]";:FORI=0TO23:PRINTQ$:NEXT
It's not too slow, and if you do as I
do, namely never print in the far
right column on the screen, you don't
have line link or scrolling problems.
Notice that Q$ is only 39 characters
long, not 40.
When the word got around a few years
back that I was a font-maniac, many
programs came in with oddball alphabet
fonts -- gothic, sanskrit, jagged
computer, double-serifed, you name it.
It took me a while to explain that the
alphabet and numbers shouldn't be
changed radically, it's the GRAPHIC
characters that can and should be
changed for special effects. Such as
making your $129 C-64 look like a
$4000 Mac.
There is another interesting line in
Brian's code. Line 30 has these
mysterious POKEs:
(1) POKE56576,4
(2) POKE53272,2
(3) POKE648,192
(4) POKE53265,27
(1) tells the VIC-II chip to change to
BANK 3 (instead of the default
BANK 0).
(2) tells the VIC-II chip that the
font is at the second 1K offset
from the start of BANK 3, or
$C800.
(3) tells the operating system that
the screen memory is in BANK 3, at
page 192, or memory location
$C000.
(4) turns the screen display on.
This is a pretty elegant way to use a
custom font without having to take
memory away from BASIC. Usually, if
my program is small (under 30 blocks
or so) I lower the top of BASIC to
page 56 and put the font at the top
of BANK 0 (at $3800). If my program
is too large for this then I raise
the start of BASIC (in a boot
program) to page 16 ($1000) and load
the font into place at page 8
($0800).
With these simple POKEs, Brian has
placed everything up in BANK 3 and
left BASIC unchanged. You can tell
when something like this has been
done. When you press RUN/STOP-RESTORE
to break out of the program to LIST
it, you find a blue screen with no
cursor. Whaaaat? The thing to do is
to type blindly
POKE648,4 [RETURN]
and the cursor will appear.
And finally, I'm amazed at the
variety of patterns that can be made
with this technique of redefining ONE
character. I wonder what M. C.
Escher would have thought.
FT
P.S. Frank Vanaman, beta-tester
extraordinaire and our man in DC, has
a good suggestion. Run FULLFONT
(from LOADSTAR #69) and load "tile
font" from this program. Then choose
FULLFONT's ITALICS feature and you'll
have a completely new set of 128
patterns, some of them very unusual.
As Frank says, "Double value for the
same price." That's the LOADSTAR
way.